/**
 * @file cmd_reboot.c
 * @brief 
 * @author  ()
 * @version 1.0
 * @date 2024-09-13
 * 
 * @copyright Copyright (C) 2019 Queclink Wireless Solutions (ShenZhen) Co., Ltd. All Rights Reserved.
 * 
 * @par 修改日志:
 * <table>
 * <tr><th>Date       <th>Version <th>Author  <th>Description
 * <tr><td>2024-09-13 <td>1.0     <td>     <td>内容
 * </table>
 */
#include "lettershell/shell.h"

#include "../shell_log.h"
#include "hal_adapter.h"

#include "misc/misc_api.h"

/// @brief 设备重启指令,注意后续迭代为dev_reboot指令，要求记录重启原因
/// @param  
/// @return 
int32_t cmd_reboot(void)
{ 
    if (0 == tbox_system_reboot(1000))
        return 0;
	
    return -1;
}

SHELL_EXPORT_CMD(SHELL_CMD_PERMISSION(0) | SHELL_CMD_TYPE(SHELL_TYPE_CMD_FUNC) | SHELL_CMD_DISABLE_RETURN,
                 reboot, cmd_reboot, reboot system);
